var ishttps = 'https:' == document.location.protocol ? true : false;
if(ishttps) {
	var http_pre = "https";
} else {
	var http_pre = "http";
}
var BASEURL = http_pre+'://ycyd.zxhong.com/api.php/';
var API = {
    banner: BASEURL + 'index/image',
    plist : BASEURL + 'index/plist',
    alist : BASEURL + 'index/alist',
    zan   : BASEURL + 'index/zan',
    years : BASEURL + 'index/years',
    config: BASEURL + 'index/config',
    lang  : BASEURL + 'index/lang'
}

function request(url,data,callback) {
    $.ajax({
        type: "GET",
        url: url,
        data: data,
        dataType: "json",
        success: callback
    });
}